<template>
  <div class="category">
    <PageContent
      :table-config="tableConfig"
      table-name="category"
      @create-click="handleCreateClick"
      @edite-click="handleEditeClick"
    />
    <PageDialog
      :dialog-config="dialogConfig"
      table-name="category"
      ref="pageDialogRef"
      :edite-data="editeData"
    />
  </div>
</template>

<script setup lang="ts">
import PageContent from '@/components/page-content/PageContent.vue';
import PageDialog from '@/components/page-dialog/PageDialog.vue';

import {tableConfig} from './config/table-config'
import {dialogConfig} from './config/dialog-config'

import useDialog from '@/hooks/useDialog';
const [ pageDialogRef,
        editeData,
        handleCreateClick,
        handleEditeClick  ] = useDialog()
</script>

<style scoped>

</style>